#ifndef _FIG_MAIN_MENU_H_
#define _FIG_MAIN_MENU_H_

#include "fig_mogaui_state.h"
#include "fig_bone_object.h"
#include "fig_shakescreen.h"
#include "mat_ui_animator.h"

namespace LuaPlus
{
	class LuaState;
}



class Fighter;

class FIGMainMenu : public FIGMOGAUIState, MATAnimatedFinishCallBack
{
public:

	FIGMainMenu(camera::FbCamera*	pCamera);
	

	/// called when the game flow manager transitions into this game state
	virtual	bool		OnEnter();

	/// called when the game flow manager transitions out of this game state
	virtual	bool		OnExit();

	/// render the help
	virtual	bool		PreRender();
	virtual	bool		PostRender();

	/// update the game
	virtual	bool		Tick(float dt);
	

	virtual void		KeyPressed(input::Keyboard::KEY* pKey);
	virtual void		OnAnimatedUIFinish();

	
	
	void DELEGATE_CALL						OnHardQuit(ui::UIWidget::WIDGET_EVENT Event, ui::UIWidget* pWidget);
	void DELEGATE_CALL						OnQuitNo(ui::UIWidget::WIDGET_EVENT Event, ui::UIWidget* pWidget);

	virtual bool							OnUIKeyDownEvent(int	KeyCode);

protected:

	// UI Stuffs
	void DELEGATE_CALL						OnButtonSettings(ui::UIWidget::WIDGET_EVENT Event, ui::UIWidget* pWidget);
	void DELEGATE_CALL						OnButtonLeaderBoard(ui::UIWidget::WIDGET_EVENT Event, ui::UIWidget* pWidget);
	void DELEGATE_CALL						OnButtonAchievements(ui::UIWidget::WIDGET_EVENT Event, ui::UIWidget* pWidget);

	void									PressedEsc();	

	FIGBoneObject							m_BoneTitle;
	bool									m_IsFinishTitleAnimation;
	FIGShakeScreen							m_ShakeScreen;
	ui::UIWidget*							m_pUI;
	
	
};

#endif //_FIG_MAIN_MENU_H_
